#pragma once

#include <stdint.h>
#include <string>
namespace myrpc::base
{

  class Dataformat
  {
  public:
    Dataformat() = delete;
    ~Dataformat() = delete;
    static inline std::string &Get_data_type(uint32_t type)
    {
      return type <= data_type_size_ ? data_type_[type] : data_type_[0];
    };
    static inline bool Data_type_is_available(uint32_t type)
    {
      return type <= data_type_size_;
    };
    static std::string data_type_[];
    static const uint32_t data_type_size_;
  };

} // namespace myrpc::base